package com.tzbank.wisdom.service.impl;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.tzbank.entity.mpass.DeviceBindInfo;
import com.tzbank.wisdom.dao.DeviceBindInfoMapper;
import com.tzbank.wisdom.service.DeviceBindInfoService;

@Service
public class DeviceBindInfoServiceImpl implements DeviceBindInfoService{

	@Resource
	private DeviceBindInfoMapper deviceBindInfoMapper;
	
	@Transactional
	@Override
	public boolean add(DeviceBindInfo info) {
		return deviceBindInfoMapper.insertSelective(info) > 0 ;
	}

	@Override
	public DeviceBindInfo findByDeviceId(String userId, String deviceId, String deviceType) {
		return deviceBindInfoMapper.findByDeviceId(userId, deviceId, deviceType);
	}

}
